package vn.personal.anhht.bloback12.util;

import java.text.SimpleDateFormat;
import java.util.Date;

public class UtilMethods {

	public static long dateToMiliSeconds(Date date){
		return date.getTime();
	}
	
	public static String changeMilisecondToDate(long miliseconds) {
		SimpleDateFormat sdf = new SimpleDateFormat("dd MMM,yyyy HH:mm ");
		Date resultDate = new Date(miliseconds);
		return sdf.format(resultDate);
	}
	
	public static String getCurrentDay(){
		SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
		return sdf.format(new Date());
	}
}
